//package com.mapper;
//
//import com.pojo.Workstation;
//import com.pojo.WorkstationStatus;
//import org.apache.ibatis.annotations.*;
//
//import java.util.List;
//
//@Mapper
//public interface WorkstationMapper {
//    // 新增工位（自动回填主键）
//    @Insert("INSERT INTO workstation (floor_id, model_identifier, status, create_time) " +
//            "VALUES (#{floorId}, #{modelIdentifier}, #{status}, #{createTime})")
//    @Options(useGeneratedKeys = true, keyProperty = "id")
//    void insert(Workstation workstation);
//
//    // 根据楼层ID查询工位列表
//    @Select("SELECT " +
//            "id, floor_id AS floorId, " +
//            "model_identifier AS modelIdentifier, " +
//            "status, create_time AS createTime " +
//            "FROM workstation WHERE floor_id = #{floorId}")
//    List<Workstation> selectByFloorId(Integer floorId);
//
//    // 根据ID查询工位详情
//    @Select("SELECT " +
//            "id, floor_id AS floorId, " +
//            "model_identifier AS modelIdentifier, " +
//            "status, create_time AS createTime " +
//            "FROM workstation WHERE id = #{id}")
//    Workstation selectById(Integer id);
//
//    // 动态更新工位信息
//    @Update("<script>" +
//            "UPDATE workstation " +
//            "<set>" +
//            "   <if test='floorId != null'>floor_id = #{floorId},</if>" +
//            "   <if test='modelIdentifier != null'>model_identifier = #{modelIdentifier},</if>" +
//            "   <if test='status != null'>status = #{status},</if>" +
//            "   update_time = NOW()" +
//            "</set>" +
//            "WHERE id = #{id}" +
//            "</script>")
//    void updateById(Workstation workstation);
//}